Component({
  properties: {
    scenicName: {
      type: String,
      value: ""
    },
    scenicDes: {
      type: String,
      value: ""
    },
    imageSrc: {
      type: String,
      value: ""
    },
    price: {
      type: Number,
      value: 0
    },
    computedPrice: {
      type: Number,
      value: 0
    },
    list: {
      type: Object,
      value: {}
    }
  },
  data: {
  },
  methods: {
    jumpGoodDetail(e) {
      const pageThis = this
      wx.navigateTo({
        url: `/pages/ticketDetail/index`,
        success(res) {
          // 通过eventChannel向被打开页面传送数据
          res.eventChannel.emit('sendOutData', { value: pageThis.properties.list , type: 'good'})
        }
      });
    }
    // jumpHotelDetail(e) {
    //   let scenicName = e.currentTarget.dataset.scenicname
    //   let scenicDes = e.currentTarget.dataset.scenicdes
    //   let imageSrc = e.currentTarget.dataset.imagesrc
    //   let price = e.currentTarget.dataset.price
    //   let computedPrice = e.currentTarget.dataset.computedprice
    //   wx.navigateTo({
    //     url: `/pages/ticketDetail/index?scenicName=${scenicName}&scenicDes=${scenicDes}&imageSrc=${imageSrc}&price=${price}&computedPrice=${computedPrice}`,
    //   });
    // }
  },
})
